<div class="referbox">
  <div class="evalubox">
    <div class="evalubox_left">
      <div class="scores">
        <ul class="out">
          <li>商品评分</li>
          <li style=" *height:22px; *padding-top:2px">
            <div class="star_div "><!--咨询页面这个地方class可调用用"star_no"-->
              <ul>
                <li class="star<{$goods_point.avg}>"></li>
              </ul>
            </div>
            <span class="scores_size"><{$goods_point.avg_num}></span></li>
          <li style="clear:both">(<{t}>共<{/t}><a href="<{link app=b2c ctl="site_comment" act="commentlist" arg0=$goods.goods_id arg1="discuss"}>" class="fontcolorRed"><{$comment.discussCount|default:'0'}></a><{t}>人评分<{/t}>)</li>
        </ul>
      </div>
      <div class="scores_li">
        <ul>
        	<{foreach from=$_all_point item="_all_point"}>
          <li><{$_all_point.type_name}>: <span class="price1"><{$_all_point.avg}></span></li>
          <{/foreach}>
        </ul>
      </div>
    </div>
    <div class="evalubox_right">
      <div class="rightbox"><h4>评价说明</h4><p><{$comment.goods_discuss_notice}></p>
</div>
      <div class="floatright"><a href="#write_discuss" class="orangebtn allnum"><i class="has-icon"> <img  style="margin:0"src='<{$env.app.res_url}>/bundle/pencil.gif' /></i><span>我要评论</span></a></div>
    </div>
  </div>
  <a name="discuss_all_info"></a>
  <div class="goods-discus-title"> <{t}>共<{/t}><span class="fontcolorRed"><{$comment.discussCount|default:'0'}></span><{t}>人评论<{/t}>&nbsp;&nbsp;<span class="all_link"><a href="#discuss_all_info" class="allnum" style=" color:#367EC1"><{t}>查看所有评论<{/t}></a></span> </div>
<div class="consult-content">
    <div class="consult-panel" id="discuss_content"><{include file="site/product/discuss_content.html"}></div>
</div>

 </div>
  
  <div style="display:none" class="displaydiv">
<!--  发表评论区域-->
<a name="write_discuss"></a>
<form class="addcomment" method="post" action='<{link app=b2c ctl=site_comment act=toComment arg0=$goods.goods_id arg1=discuss}>' onsubmit='checkFormReqs(event);'>
      <div class="review_box">
      <h4 class="review_title"><{t}>发表评论<{/t}><span>（点击五角星评分）</span></h4>
<div class="division">
      <div class="leftbox">
      <div class="review_textarea"> 
      <ul>
      <li> 
      	<div class="start-point" style=""><!--咨询页面这个class可以调用"nodisplay"-->
        
	          <{foreach from=$comment_goods_type item=comment_goods_type}>
	          <div class="clearfix">
				<div class="span-auto">
				<label><{$comment_goods_type.name}></label>
				</div>
				<div id="rate_<{$comment_goods_type.type_id}>" class="star-point-items span-auto">
					<div class="b">&nbsp;</div>
					<div class="f">&nbsp;</div>
				</div>
				<div class="span-auto font11px fontcolorOrange">
				</div>
				<input type='hidden' name="point_type[<{$comment_goods_type.type_id}>][point]"/>
			   </div>
	          <{/foreach}>
	     </div>
      </li>
    	<li><{input type="textarea" class="x-input inputstyle"  vtype="sendcomments" rows="5" name="comment" style="display:block;width:80%;"}> <span class="infotips">字数限制为5-200个</span></li>
          <{if $login eq "nologin"}>
        <li><{t}>联系方式：<{/t}> <{input type="text" vtype=required class="inputstyle"  size=20 name="contact"}><span class="infotips"><{t}>(可以是电话、email、qq等).<{/t}></span></li>
          <{/if}>
          <{if $discussshow == "on"}>
            <li><{t}>验证码：<{/t}>
			<{input type="number" vtype=required size="4" maxlength="4" name="discussverifyCode"}>&nbsp;<img src="<{link app="b2c" ctl="site_comment" act="gen_dissvcode" arg0=$smarty.now}>" border="1" id="discussimgVerifyCode"/><a href="javascript:changeimg('discussimgVerifyCode','discuss')">&nbsp;<{t}>看不清楚?换个图片<{/t}></a>
            </li>
          <{/if}>
            <{if $login != "nologin"}>
            <li>
              <{t}>匿名发表:<{/t}>
              <input type="checkbox" name="hidden_name" value="YES"/>
            </li>
            <{/if}>
    	<li style="padding-left:0"><button id="cart-coupon-submitBtn" class="btn dicusbtn " type="submit"> <span><span> <{t}>提交评论<{/t}></span></span> </button></li>
      </ul>
      </div>
      
      </div>
      <div class="rightbox"><p><{$comment.submit_comment_notice.discuss}></p>
</div>
        <div class="clear"></div>
      </div>
      </div>
    </form>
</div>

	 <script>

		window.addEvent('domready',function(){
			$$('.star-point-items').each(function(i){
					var _c = i.getNext();
					var _b = i.getElement('.b');
					var _f = i.getElement('.f');
					var _ipt = i.getNext('input');
						_ipt.value = 0;
					i.addEvents({
							'mousemove':function(e){	
								var offset = (e.page.x - i.getPosition([document.body]).x);
								var _left = (offset-i.offsetWidth).limit(0-i.offsetWidth,0);
								var count  = (5*((i.offsetWidth + _left)/(i.offsetWidth)));
									if(count<0.3){count  = 0}else{count = Math.ceil(count);}
								_b.setStyle('left',i.offsetWidth*(count/5) - i.offsetWidth);
								_c.set('text',_ipt.value = count);
							},
							mouseenter:function(e){
								this.fireEvent('mousemove',e);
							}
					});
					/*fix png*/
					if(window.ie6){
						_f.setStyles({
							'filter':'progid:DXImageTransform.Microsoft.AlphaImageLoader(enabled=true, sizingMethod=image, src='+_f.getStyle('background-image').match(/url\(([^\)]*)/)[1]+')',
							'background':'none'
						});
					}
			});
			
		});
	</script>
